$(()=>{

    if (success){
        layer.msg("添加成功");
        setTimeout(function (){
            parent.location.reload();
        },500);
    }
    //入库日期框设置时间选择
    laydate.render({
        elem: "#entryTime"
    });

    if (error){
        layer.msg(error)
    }
    //确认按钮添加事件
    $("#confirm").click(function (e){
        e.preventDefault();

        //前端校验
        let warehouseId = $("#warehouseId").val();
        let commodityId = $("#commodityId").val();
        let inventory = $("#inventory").val();
        let entryTime = $("#entryTime").val();

        //todo

        $("#inventoryForm").submit();

    })

})